package com.molichuxing.services.business.service;

import java.util.List;
import java.util.Map;

import com.molichuxing.framework.dto.Paged;
import com.molichuxing.framework.service.RootService;
import com.molichuxing.services.business.dto.request.create.OrderExclusivelCreateBizDto;
import com.molichuxing.services.business.dto.request.modify.OrderModifyBizDto;
import com.molichuxing.services.business.dto.request.modify.OrderPayModifyBizDto;
import com.molichuxing.services.business.dto.response.CarOrderBizDto;
import com.molichuxing.services.business.dto.response.LedgerRepaymentPeriodBizDto;
import com.molichuxing.services.business.dto.response.OrderCarInfoAppDto;
import com.molichuxing.services.business.dto.response.OrderExclusivelBizDto;
import com.molichuxing.services.business.dto.response.OrderExclusivelDetailsBizDto;
import com.molichuxing.services.business.dto.response.UserOrderBizDto;

/**
 * 专属里程订单组合服务
 * 
 * @author zoumingyu
 * @date 2019年8月12日
 *
 */
public interface OrderExclusivelBizService extends RootService {

	/**
	 * 分页获取专属里程订单信息
	 *
	 * @param params
	 *            listType：列表类型-enum <br/>
	 *            orderStatus：订单状态-enum <br/>
	 *            orderCode：订单号-long <br/>
	 *            userIds：用户id-list <br/>
	 *            storeIds：门店id-list <br/>
	 *            orderTimeStart：下单开始时间-LocalDateTime <br/>
	 *            orderTimeEnd：下单结束时间-LocalDateTime
	 * @param pageNum
	 *            页数
	 * @param pageSize
	 *            每页条数
	 * @return
	 * @throws Exception
	 */
	public Paged<OrderExclusivelBizDto> getOrderList(Map<String, Object> params, int pageNum, int pageSize)
			throws Exception;

	/**
	 * 根据用户id查询专属里程订单信息
	 * 
	 * @param userId
	 *            用户id
	 * @return
	 */
	public List<UserOrderBizDto> getOrderExclusivelByUser(Integer userId);

	/**
	 * 根据车辆id查询专属里程订单信息
	 * 
	 * @param carId
	 *            车辆id
	 * @return
	 */
	public List<CarOrderBizDto> getOrderExclusivelByCar(Integer carId);

	/**
	 * 根据车辆id查询专属里程订单信息
	 * 
	 * @param carId
	 *            车辆id
	 * @param storeIds
	 *            门店ids
	 * @return
	 */
	public List<CarOrderBizDto> getOrderExclusivelByCar(Integer carId, List<Integer> storeIds);

	/**
	 * 根据条件查询付款周期
	 * 
	 * @param params
	 * @return
	 */
	public Map<LedgerRepaymentPeriodBizDto, String> getRepaymentPeriod(List<LedgerRepaymentPeriodBizDto> params);

	/**
	 * 查询用车中的车辆id
	 * @param userId
	 * @return
	 */
	public List<OrderCarInfoAppDto> getOrderExclusivelCarIdByUser(Integer userId, Integer orderStatus);

	/**
	 * 订阅里程订单详情信息（包涵交车、还车等相关信息）
	 * 
	 * @param orderCode
	 *            订单号
	 * @return
	 */
	public OrderExclusivelDetailsBizDto getOrderExclusivelDetails(Long orderCode);

	/**
	 * 新增专属里程订单
	 * 
	 * @param createDto
	 * @return 订单号
	 */
	public Long createOrderExclusivel(OrderExclusivelCreateBizDto createDto);

	/**
	 * 订单状态修改
	 * 
	 * @param modifyDto
	 * @return
	 */
	public Boolean modifyExclusivelStatus(OrderModifyBizDto modifyDto);

	/**
	 * 支付成功后修改订单信息
	 * 
	 * @param modifyDto
	 * @return
	 */
	public Boolean modifyPaySuccess(OrderPayModifyBizDto modifyDto);
}
